package com.zwj.batch.config.springBatch.listener.step;

import org.springframework.batch.core.ExitStatus;
import org.springframework.batch.core.StepExecution;
import org.springframework.batch.core.StepExecutionListener;

/**
 * @author 张文接
 * @version 1.0
 * @createTime 2023/6/24 14:11
 */
public class MyStepListener implements StepExecutionListener {
    @Override
    public void beforeStep(StepExecution stepExecution) {
        System.err.println("==========step前置操作===========");
    }

    @Override
    public ExitStatus afterStep(StepExecution stepExecution) {
        System.err.println("==========step后置操作===========");
        return stepExecution.getExitStatus();
    }
}
